//
//  HEChatManager.h
//  HealthFamily
//
//  Created by 吴欧 on 2020/12/3.
//  Copyright © 2020 honglutec. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "HEIMMessageModel.h"
#import "HESocketManager.h"

NS_ASSUME_NONNULL_BEGIN

@protocol HEChatManagerDelegate <NSObject>

- (void)sendMessageHandler:(HEIMMessageModel *)message;

@end

@interface HEChatManager : NSObject

@property (nonatomic, weak) id <HEChatManagerDelegate> delegate;

+ (instancetype)sharedManager;

/**
 *  设置发送主题
 */
- (void)setupEmitKey:(NSString *)emitKey;

/**
 *  开始发送队列消息
 */
- (void)sendQueueIMMassage;


/**
 *  获取缓存消息
 */
- (NSArray <HEIMMessageModel *>*)getIMCacheWithSession:(HEIMSession *)session;

/**
 *  发送消息
 *  @param message 消息
 */
- (void)sendMessage:(HEIMMessageModel *)message;

@end

NS_ASSUME_NONNULL_END
